home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Developer Helper 1: Phil & Dave's Excellent CD
/
Excellent CD HFS.raw
/
Moof
/
Goodies
/
MPW Goodies
/
MPW Goodies⁄DTS
/
CheckedOutFiles
< prev
next >
Wrap
Text File
|
2022-08-05
|
2KB
|
82 lines
#
# File: CheckedOutFiles
#
# Contains: CheckedOutFiles echos the names of the files checked out modifiable
# in the current project.
#
# Written by: Bruce Horn, Steve Capps, Larry Kenyon,
# John Meier, scott douglass, Darin Adler,
# Paul Mercer, Bryan Stearns, Dave Owens
#
# Copyright: © 1988-1989 by Apple Computer, Inc., all rights reserved.
#
# Change History:
#
# 2/17/89 sad written from CheckInAll
#
# To Do:
# Can’t handle file names with spaces.
#
Set Exit 0
# the following helps to debug until MPW sends echos to Dev:Console instead of Dev:StdErr
If {Echo} == 1
Set somewhere "≥≥ '{Worksheet}∂'"
Else
Set somewhere '≥ Dev:Null'
End
Begin
# first get all the check-out directories for the current project
Set CheckOutDirs "`CheckOutDir -r; Set CheckOutDirStatus {Status} ; Echo ""`"
Exit {CheckOutDirStatus} If {CheckOutDirStatus} != 0
Loop
Break If "{CheckOutDirs}" !~ / *CheckOutDir +-project ∂'«0,1»([¬:]+∫)®1∂'«0,1» ∂'«0,1»([¬∫]*:)®2∂'«0,1» (≈)®3/
Set Project "{®1}"
Set CheckOutDir "{®2}"
Set CheckOutDirs "{®3}"
# now for each directory, get all modified files in the project
Set Info "`ProjectInfo -s -a "{User}" -m -project "{Project}"; Set ProjectInfoStatus {Status}`"
# *** check status here
Set FirstNotOpened ""
Set OthersNotOpened ""
Loop
Break If "{Info}" !~ /[¬+]* ([¬,]+)®1,[0-9.a-z]+∂+ (≈)®2/
Set File "{®1}"
Set Info "{®2}"
If "`Exists "{CheckOutDir}{File}"`" == ""
If "{FirstNotOpened}" == ""
Set FirstNotOpened "“{File}”"
Else
Set OthersNotOpened "{OthersNotOpened}, “{File}”"
End
Else
Quote "{CheckOutDir}{File}"
End
End
# If "{Info}" != ""
# Echo "### CheckedOutFiles - Couldn’t parse: " "{Info}" ∑∑ "{Worksheet}"
# Exit 1
# End
If "{FirstNotOpened}" != ""
If "{OthersNotOpened}" == ""
Alert "{FirstNotOpened} is checked out from “`Project -q`” but is not in the directory “{CheckOutDir}”."
Else
Alert "The following files are checked out from “`Project -q`” but are not in the directory “{CheckOutDir}”: {FirstNotOpened}{OthersNotOpened}."
End
End
End
If "{CheckOutDirs}" != ""
Echo "### CheckedOutFiles - Couldn’t parse: " "{CheckOutDirs}" ∑∑ "{Worksheet}"
Exit 1
End
End {somewhere}